<#ftl strip_whitespace=true>
<#--
<@s.url />
-->
<#macro url relativeUrl>${springMacroRequestContext.getContextPath()}${relativeUrl}</#macro>

<#--
<@s.css />
-->
<#macro css relativeUrl>
	<#if relativeUrl?is_string>
		<link rel="stylesheet" type="text/css" href="${springMacroRequestContext.getContextPath()}/style/${relativeUrl}?_=${__version}" /><#rt/>
	<#else>
		<#list relativeUrl as url>
			<link rel="stylesheet" type="text/css" href="${springMacroRequestContext.getContextPath()}/style/${url}?_=${__version}" /><#rt/>
		</#list>
	</#if>
</#macro>

<#--
<@s.script />
-->

<#macro script relativeUrl>
	<#if relativeUrl?is_string>
		<script type="text/javascript" src="${springMacroRequestContext.getContextPath()}/script/${relativeUrl}?_=${__version}"></script><#rt/>
	<#else>
		<#list relativeUrl as url>
		<script type="text/javascript" src="${springMacroRequestContext.getContextPath()}/script/${url}?_=${__version}"></script><#rt/>
		</#list>
	</#if>
</#macro>


<#--
<@s.captcha />
-->
<#macro captcha id='captchaImage'>
<img src="/security/captcha.htm?_=${__random}" id="${id}" style="cursor:pointer;" onclick="this.src = '/security/captcha.htm?_='+Math.random()" title="点击更换验证码"/> 
</#macro>


<#--
<@s.message />
-->
<#macro message >
<div id="re_message" style="display:none"></div>
<script type="text/javascript">
	var messaget = null;
	function showMessage(message,style){
		clearTimeout(messaget);
		$('#re_message').html(message).removeAttr("class").addClass("message_"+style).show();
		messaget = setTimeout(function(){$("#re_message").hide();},10*1000); //10秒后自动隐藏消息
	} 
	<#if message_fail?? && message_fail !='' >
		showMessage("${message_fail}","fail")
	</#if>
	<#if message_success?? && message_success !='' >
		showMessage("${message_success}","success")
	</#if>
</script>
</#macro>